import Vue from 'vue'
import VueRouter from 'vue-router'
import test from '../views/home.vue'
import login from '../views/login.vue'
import user from '../views/user.vue'
import statis_pls from '../views/statis_pls.vue'
import statis_3d from '../views/statis_3d.vue'
import recharge from '../views/recharge.vue'
import image_upload from '../views/image_upload.vue'
import video_upload from '../views/video_upload.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/home',
    name: 'home',
    component: test,
    children: [
      {
        path: '/user',
        name: 'user',
        component: user
      },
      {
        path: '/statis_pls',
        name: 'statis_pls',
        component: statis_pls
      },
      {
        path: '/statis_3d',
        name: 'statis_3d',
        component: statis_3d
      },
      {
        path: '/recharge',
        name: 'recharge',
        component: recharge
      },
      {
        path: '/image_upload',
        name: 'image_upload',
        component: image_upload
      },
      {
        path: '/video_upload',
        name: 'video_upload',
        component: video_upload
      },
    ]
   
  },
  {
    path: '/',
    name: 'login',
    component: login
  }
]

const router = new VueRouter({
  routes
})
export default router